using System;
using System.Runtime.Serialization;

namespace Evaluant.OPath
{
	[Serializable]
    public class OPathException : ApplicationException
	{
        public OPathException(OPathQuery query)
            : base(String.Concat("Error while compiling the opath query.\n", query.ErrorMessage))
        {
        }

        public OPathException(string message)
            : base(String.Concat("Error while compiling the opath query.\n", message))
        {
        }

        protected OPathException(SerializationInfo info, StreamingContext context)
            : base(info, context)
        {
        }
	}
}
